#coding=utf-8
#Boa:Frame:FrameFinance

import wx

def create(parent):
    return FrameFinance(parent)

[wxID_FRAMEFINANCE, wxID_FRAMEFINANCENB, 
] = [wx.NewId() for _init_ctrls in range(2)]

class FrameFinance(wx.Frame):
    def _init_ctrls(self, prnt):
        # generated method, don't edit
        wx.Frame.__init__(self, id=wxID_FRAMEFINANCE, name=u'FrameFinance',
              parent=prnt, pos=wx.Point(519, 206), size=wx.Size(1016, 738),
              style=wx.DEFAULT_FRAME_STYLE, title=u'\u8d22\u52a1\u62a5\u8868')
        self.SetClientSize(wx.Size(1000, 700))
        self.SetFont(wx.Font(12, wx.SWISS, wx.NORMAL, wx.BOLD, False,
              u'\u6977\u4f53_GB2312'))
        self.SetBackgroundColour(wx.Colour(183, 209, 173))
        self.Bind(wx.EVT_CLOSE, self.OnFrameFinanceClose)

        self.nb = wx.Notebook(id=wxID_FRAMEFINANCENB, name=u'nb', parent=self,
              pos=wx.Point(0, 0), size=wx.Size(1000, 700), style=0)

    def __init__(self, parent):
        self._init_ctrls(parent)
        
        self.myInit()

    def myInit(self):
        import PanelAssets
        import PanelIncomeStatement
        import PanelCashFlow
        import PanelProfitProduct
        
        self.panelAssets = PanelAssets.PanelAssets(self.nb)
        self.nb.AddPage(imageId=-1, page=self.panelAssets, select=True,
                    text=u'资产负债表')

        self.panelIncome = PanelIncomeStatement.PanelIncomeStatement(self.nb)
        self.nb.AddPage(imageId=-1, page=self.panelIncome, select=False,
                    text=u'损益表')
                                
        self.panelCash = PanelCashFlow.PanelCashFlow(self.nb)
        self.nb.AddPage(imageId=-1, page=self.panelCash, select=False,
                    text=u'现金流量表')
                    
        self.panelProfit = PanelProfitProduct.PanelProfitProduct(self.nb)
        self.nb.AddPage(imageId=-1, page=self.panelProfit, select=False,
                    text=u'商品利润评估')
                    

    def OnFrameFinanceClose(self, event):
        self.Show(False)    
